create-lifecycle-module(1)  asadmin Utility Subcommands  create-lifecycle-module(1)

NAME
       create-lifecycle-module - creates a lifecycle module

SYNOPSIS
           create-lifecycle-module [--help] --classname classname
            [--enabled={true|false}] [--target target]
            [--classpath classpath] [--loadorder loadorder]
            [--failurefatal={false|true} ] [--description description]
            [--property (name=value)[:name=value]*]
            module_name

DESCRIPTION
       The create-lifecycle-module subcommand creates a lifecycle module. A
       lifecycle module provides a means of running a short or long duration
       Java-based task at a specific stage in the server life cycle. This
       subcommand is supported in remote mode only.

OPTIONS
       --help, -?
           Displays the help text for the subcommand.

       --classname
           This is the fully qualified name of the startup class.

       --target
           Indicates the location where the lifecycle module is to be created.
           Valid values are

           *   server- Specifies the default server instance as the target for
               creating the lifecycle module.  server is the name of the
               default server instance and is the default value for this
               option.

           *   cluster_name- Specifies a particular cluster as the target for
               creating the lifecycle module.

           *   instance_name- Specifies a particular stand-alone server
               instance as the target for creating the lifecycle module.

       --classpath
           This option indicates where the lifecycle module is located. It is
           a classpath with the standard format: either colon-separated (Unix)
           or semicolon-separated (Windows) JAR files and directories. The
           referenced JAR files and directories are not uploaded to the server
           instance.

       --loadorder
           This option represents an integer value that can be used to force
           the order in which deployed lifecycle modules are loaded at server
           startup. Smaller numbered modules are loaded sooner. Order is
           unspecified if two or more lifecycle modules have the same
           load-order value. The default is Integer.MAX_VALUE, which means the
           lifecycle module is loaded last.

       --failurefatal
           This option tells the system what to do if the lifecycle module
           does not load correctly. When this option is set to true, the
           system aborts the server startup if this module does not load
           properly. The default value is false.

       --enabled
           This option determines whether the lifecycle module is enabled at
           runtime. The default value is true.

       --description
           This is the text description of the lifecycle module.

       --property
           This is an optional attribute containing name/value pairs used to
           configure the lifecycle module.

OPERANDS
       module_name
           This operand is a unique identifier for the deployed server
           lifecycle event listener module.

EXAMPLES
       Example 1, Creating a Lifecycle Module
           The following example creates a lifecycle module named customSetup.

               asadmin> create-lifecycle-module --classname "com.acme.CustomSetup"
               --classpath "/export/customSetup" --loadorder 1 --failurefatal=true
               --description "this is a sample customSetup"
               --property rmi="Server\=acme1\:7070":timeout=30 customSetup
               Command create-lifecycle-module executed successfully
           The escape character \ is used in the property option to specify
           that the equal sign (=) and colon (:) are part of the rmi property
           value.

EXIT STATUS
       0
           command executed successfully

       1
           error in executing the command

SEE ALSO
       delete-lifecycle-module(1), list-lifecycle-modules(1)

       asadmin(1M)

       "Developing Lifecycle Listeners" in Oracle GlassFish Server Application
       Development Guide

Java EE 8                  09 Aug 2017            create-lifecycle-module(1)
